
# Loop
Common=[]
for i in ListA:
    if i in ListB:
        Common.append(i)
if len(Common) == 0:
    print('No common element.')
else:
    for i in Common:
        print(i)
# Set
SetA=set(ListA)
SetB=set(ListB)
Common=SetA&SetB
if len(Common) == 0:
    print('No common element.')
else:
    for i in Common:
        print(i)
